package com.object.demo2;
/*
 * 
 * 计算圆的面积
 * 
 */
public class CircleTest {
	public static void main(String[] args) {
		Circle c1 = new Circle();
//		c1.radius= 4;
//		System.out.println(c1.findArea());
		double area = c1.sumArea(4);
		System.out.println(area);
	}

}


class Circle{
//	double radius;
//	
//	public double findArea(){
//		double area = Math.PI*radius*radius;
//		return area;
//	}
	
	public double sumArea(double r){
			double area = Math.PI*r*r;
			return area;
	}
	
}